package com.wish233.wiliwilicommon.constants;

/**
 * Redis常量类
 * @author WHH
 */
public interface RedisConstants {
    String CODE_KEY = "cache:code:";
    Long LOGIN_CODE_TTL = 2L;
    String LOGIN_USER_KEY = "cache:login:";
    Long LOGIN_USER_TTL = 2L;
    String LIKE_BLOG_KEY = "user:like:blog:";

    String REPEAT_SUBMIT_KEY = "repeat:";
    String THREAD_CHART_KEY = "thread:";
    Long THREAD_CHART_TTL = 5L;

    //视频播放量
    String VIDEO_VIEWS = "video:views:";
    Long VIDEO_VIEWS_TTL = 100L;

    //视频查找
    String VIDEO_GET = "video:get:";
    Long VIDEO_GET_TTL = 100L;

    //签到分布式锁
    String SIGN_IN_LOCK_KEY = "sign:lock:";
    Long SIGN_IN_LOCK_TTL = 5L;

    //视频上传update
    String VIDEO_UPDATE = "video:update:";
    Long VIDEO_UPDATE_TTL = 5L;

    //点赞
    //点赞集合 like:set:{biz_id}:{message_id}
    String LIKE_SET_KEY = "like:set:";
    Long LIKE_SET_TTL = 100L;

    //点赞数量 like:count:{biz_id}:{message_id}
    String LIKE_COUNT_KEY = "like:count:";
    Long LIKE_COUNT_TTL = 100L;

    //评论
    String COMMENT_KEY = "comment:";
    Long COMMENT_TTL = 100L;

    //视频评论缓存
    String COMMENT_ROOT_VIDEO_KEY = "comment:root:video:";

    //视频评论缓存
    String COMMENT_CHILD_VIDEO_KEY = "comment:child:video:";

    //视频播放量限流器
    String VIDEO_VIEWS_LIMITER_KEY = "video:views:limiter:";

    //历史记录 {id}
    String HISTORY_VIDEO_KEY = "history:video:";
    String HISTORY_VIDEO_TIME_KEY = "history:video:time:";
    Long HISTORY_VIDEO_TTL = 2L;

    // 点赞消息唯一id like:mq:{id}
    String LIKE_MQ_ID_KEY = "like:mq:";
    Long LIKE_MQ_ID_TTL = 5L;


}
